const { ipcMain } = require("electron");
const { readdir } = require("fs/promises");
const path = require("path");

const getFileList = async (e, args) => {
    const fileList = await readdir(path.resolve(__dirname, "../public/uploads"));
    return fileList;
};
ipcMain.handle("on-getFileList-event", getFileList);